mkdir swap
cd swap
# (1024*4000000=4G)
sudo dd if=/dev/zero of=swapfile bs=1024 count=4000000 
sudo mkswap swapfile 
sudo chmod 0600 swapfile 
sudo swapon swapfile
swapoff -a

